﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Text;
using System.Threading.Tasks;
using Assistant;
using Microsoft.Phone.Info;

/**
 * 创建时间：2014/10/12 18:16:16
 * 作者：yong.blackcore
 * Email：itblackhole@outlook.com
 * QQ：50404503
 */
namespace YoucaiReader.Helper
{

    public class GetHttpInfoHelper
    {
        public static WebHeaderCollection GetHttpHeaders()
        {
            WebHeaderCollection headers = new WebHeaderCollection();
            if (SettingHelper.IsSettings("QQReader_sid"))
            {
                headers["sid"] = SettingHelper.GetValueFromSettings("QQReader_sid") as string;
            }
            headers["c_version"] = "qqreader_1.0.0_0001_wp7";
            string str = DeviceExtendedProperties.GetValue("DeviceName").ToString();
            if (str.Length > 0)
            {
                headers["ua"] = str;
            }
            headers["usid"] = "-1";
            headers["c_platform"] = "wp7";
            headers["pageId"] = App.QQReader_pageId;
            headers["prePageId"] = App.QQReader_prePageId;
            return headers;
        }
    }
}

